<!-- HTML header for doxygen 1.8.9.1-->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.6"/>
<title>ROSS: core/rand-clcg4.c File Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td style="padding-left: 0.5em;">
   <a href="https://github.com/ROSS-org/ROSS">
   <div id="projectname">ROSS
   </div>
   </a>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.6 -->
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li><a href="pages.html"><span>Related&#160;Pages</span></a></li>
      <li><a href="annotated.html"><span>Data&#160;Structures</span></a></li>
      <li class="current"><a href="files.html"><span>Files</span></a></li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="files.html"><span>File&#160;List</span></a></li>
      <li><a href="globals.html"><span>Globals</span></a></li>
    </ul>
  </div>
<div id="nav-path" class="navpath">
  <ul>
<li class="navelem"><a class="el" href="dir_af18cf245e3394ab3b436135935cfd6e.html">core</a></li>  </ul>
</div>
</div><!-- top -->
<div class="header">
  <div class="summary">
<a href="#define-members">Macros</a> &#124;
<a href="#func-members">Functions</a> &#124;
<a href="#var-members">Variables</a>  </div>
  <div class="headertitle">
<div class="title">rand-clcg4.c File Reference</div>  </div>
</div><!--header-->
<div class="contents">

<p>RNG Implementation module.  
<a href="#details">More...</a></p>
<div class="textblock"><code>#include &lt;<a class="el" href="ross_8h_source.html">ross.h</a>&gt;</code><br/>
</div>
<p><a href="rand-clcg4_8c_source.html">Go to the source code of this file.</a></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="define-members"></a>
Macros</h2></td></tr>
<tr class="memitem:abec92cc72a096640b821b8cd56a02495"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rand-clcg4_8c.html#abec92cc72a096640b821b8cd56a02495">H</a>&#160;&#160;&#160;32768</td></tr>
<tr class="separator:abec92cc72a096640b821b8cd56a02495"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a2888609ddc8a467786e86846bec7ddb9"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rand-clcg4_8c.html#a2888609ddc8a467786e86846bec7ddb9">S0_MAX</a>&#160;&#160;&#160;2147483646</td></tr>
<tr class="separator:a2888609ddc8a467786e86846bec7ddb9"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a0b3e49b839fa2dd23a2fddf31aaf6ad2"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rand-clcg4_8c.html#a0b3e49b839fa2dd23a2fddf31aaf6ad2">S1_MAX</a>&#160;&#160;&#160;2147483542</td></tr>
<tr class="separator:a0b3e49b839fa2dd23a2fddf31aaf6ad2"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a5a44a44cb9212f0097f9beec79cc8d41"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rand-clcg4_8c.html#a5a44a44cb9212f0097f9beec79cc8d41">S2_MAX</a>&#160;&#160;&#160;2147483422</td></tr>
<tr class="separator:a5a44a44cb9212f0097f9beec79cc8d41"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ac708ebfb62ad4528bedaeffbe28a3e06"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rand-clcg4_8c.html#ac708ebfb62ad4528bedaeffbe28a3e06">S3_MAX</a>&#160;&#160;&#160;2147483322</td></tr>
<tr class="separator:ac708ebfb62ad4528bedaeffbe28a3e06"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a>
Functions</h2></td></tr>
<tr class="memitem:ac243c54261ecf17a1b848e9b9a2025a9"><td class="memItemLeft" align="right" valign="top">long long&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rand-clcg4_8c.html#ac243c54261ecf17a1b848e9b9a2025a9">FindB</a> (long long a, long long k, long long m)</td></tr>
<tr class="memdesc:ac243c54261ecf17a1b848e9b9a2025a9"><td class="mdescLeft">&#160;</td><td class="mdescRight">Find B to run CLCG4 backwards.  <a href="#ac243c54261ecf17a1b848e9b9a2025a9">More...</a><br/></td></tr>
<tr class="separator:ac243c54261ecf17a1b848e9b9a2025a9"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ab89ab01c93d79746cff9a7ed763b24d3"><td class="memItemLeft" align="right" valign="top">int32_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rand-clcg4_8c.html#ab89ab01c93d79746cff9a7ed763b24d3">MultModM</a> (int32_t s, int32_t t, int32_t M)</td></tr>
<tr class="memdesc:ab89ab01c93d79746cff9a7ed763b24d3"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns(s*t) MOD M.  <a href="#ab89ab01c93d79746cff9a7ed763b24d3">More...</a><br/></td></tr>
<tr class="separator:ab89ab01c93d79746cff9a7ed763b24d3"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:af6fe13cfedc4e727feee7b28869e036e"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rand-clcg4_8c.html#af6fe13cfedc4e727feee7b28869e036e">clamp_seed</a> (uint32_t s[4])</td></tr>
<tr class="separator:af6fe13cfedc4e727feee7b28869e036e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a9c251d8e1876abc122b55fe4156ce14c"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rand-clcg4_8c.html#a9c251d8e1876abc122b55fe4156ce14c">rng_set_seed</a> (<a class="el" href="structtw__rng__stream.html">tw_rng_stream</a> *g, uint32_t s[4])</td></tr>
<tr class="separator:a9c251d8e1876abc122b55fe4156ce14c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ad0fa533d1469c99034b45cd302a5134c"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rand-clcg4_8c.html#ad0fa533d1469c99034b45cd302a5134c">rng_write_state</a> (<a class="el" href="structtw__rng__stream.html">tw_rng_stream</a> *g, FILE *f)</td></tr>
<tr class="separator:ad0fa533d1469c99034b45cd302a5134c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aaf057a5d3e55f2174f5100a2058f37c5"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rand-clcg4_8c.html#aaf057a5d3e55f2174f5100a2058f37c5">rng_get_state</a> (<a class="el" href="structtw__rng__stream.html">tw_rng_stream</a> *g, uint32_t s[4])</td></tr>
<tr class="separator:aaf057a5d3e55f2174f5100a2058f37c5"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa97731a64b1cf687109f7a5f8f519c68"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rand-clcg4_8c.html#aa97731a64b1cf687109f7a5f8f519c68">rng_put_state</a> (<a class="el" href="structtw__rng__stream.html">tw_rng_stream</a> *g, uint32_t s[4])</td></tr>
<tr class="separator:aa97731a64b1cf687109f7a5f8f519c68"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a29a7a9b6a079ced3ba8339a66856fa82"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rand-clcg4_8c.html#a29a7a9b6a079ced3ba8339a66856fa82">rng_init_generator</a> (<a class="el" href="structtw__rng__stream.html">tw_rng_stream</a> *g, <a class="el" href="rand-clcg4_8h.html#a3481da76773e3f2621af85e5865484a5">SeedType</a> Where)</td></tr>
<tr class="separator:a29a7a9b6a079ced3ba8339a66856fa82"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a9179f0148c620729309111ad61a3fa5b"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rand-clcg4_8c.html#a9179f0148c620729309111ad61a3fa5b">tw_rand_initial_seed</a> (<a class="el" href="structtw__rng__stream.html">tw_rng_stream</a> *g, <a class="el" href="ross_8h.html#a911515dff2fb79886a16ed44df5f9d20">tw_lpid</a> id)</td></tr>
<tr class="separator:a9179f0148c620729309111ad61a3fa5b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a96c2fb54945c414a31ce0512c39622b0"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rand-clcg4_8c.html#a96c2fb54945c414a31ce0512c39622b0">tw_rand_init_streams</a> (<a class="el" href="structtw__lp.html">tw_lp</a> *lp, unsigned int nstreams)</td></tr>
<tr class="separator:a96c2fb54945c414a31ce0512c39622b0"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a3c5ea1f9125b9534b62a80dbfa20dafb"><td class="memItemLeft" align="right" valign="top"><a class="el" href="structtw__rng.html">tw_rng</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rand-clcg4_8c.html#a3c5ea1f9125b9534b62a80dbfa20dafb">rng_init</a> (int v, int w)</td></tr>
<tr class="separator:a3c5ea1f9125b9534b62a80dbfa20dafb"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:adc7b882f7220d319c89b7500c5d2395f"><td class="memItemLeft" align="right" valign="top">double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rand-clcg4_8c.html#adc7b882f7220d319c89b7500c5d2395f">rng_gen_val</a> (<a class="el" href="structtw__rng__stream.html">tw_rng_stream</a> *g)</td></tr>
<tr class="separator:adc7b882f7220d319c89b7500c5d2395f"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa596cdb21f9c04984cc4806d7357d542"><td class="memItemLeft" align="right" valign="top">double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rand-clcg4_8c.html#aa596cdb21f9c04984cc4806d7357d542">rng_gen_reverse_val</a> (<a class="el" href="structtw__rng__stream.html">tw_rng_stream</a> *g)</td></tr>
<tr class="separator:aa596cdb21f9c04984cc4806d7357d542"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="var-members"></a>
Variables</h2></td></tr>
<tr class="memitem:a5bb18b1128fadea0f468ea648f656ce1"><td class="memItemLeft" align="right" valign="top">static <a class="el" href="structtw__rng.html">tw_rng</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rand-clcg4_8c.html#a5bb18b1128fadea0f468ea648f656ce1">rng</a> = NULL</td></tr>
<tr class="separator:a5bb18b1128fadea0f468ea648f656ce1"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ac6110bfd61d392bab210049c5f6f8fa3"><td class="memItemLeft" align="right" valign="top">int32_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rand-clcg4_8c.html#ac6110bfd61d392bab210049c5f6f8fa3">seed</a> [4] = { 11111111, 22222222, 33333333, 44444444 }</td></tr>
<tr class="separator:ac6110bfd61d392bab210049c5f6f8fa3"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>Random number generator, provides all of the features GTW requires by default. Chris hacked this pretty well, he would know the features better. </p>

<p>Definition in file <a class="el" href="rand-clcg4_8c_source.html">rand-clcg4.c</a>.</p>
</div><h2 class="groupheader">Macro Definition Documentation</h2>
<a class="anchor" id="abec92cc72a096640b821b8cd56a02495"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define H&#160;&#160;&#160;32768</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Definition at line <a class="el" href="rand-clcg4_8c_source.html#l00020">20</a> of file <a class="el" href="rand-clcg4_8c_source.html">rand-clcg4.c</a>.</p>

<p>Referenced by <a class="el" href="rand-clcg4_8c_source.html#l00077">MultModM()</a>.</p>

</div>
</div>
<a class="anchor" id="a2888609ddc8a467786e86846bec7ddb9"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define S0_MAX&#160;&#160;&#160;2147483646</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Definition at line <a class="el" href="rand-clcg4_8c_source.html#l00144">144</a> of file <a class="el" href="rand-clcg4_8c_source.html">rand-clcg4.c</a>.</p>

<p>Referenced by <a class="el" href="rand-clcg4_8c_source.html#l00153">clamp_seed()</a>.</p>

</div>
</div>
<a class="anchor" id="a0b3e49b839fa2dd23a2fddf31aaf6ad2"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define S1_MAX&#160;&#160;&#160;2147483542</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Definition at line <a class="el" href="rand-clcg4_8c_source.html#l00145">145</a> of file <a class="el" href="rand-clcg4_8c_source.html">rand-clcg4.c</a>.</p>

<p>Referenced by <a class="el" href="rand-clcg4_8c_source.html#l00153">clamp_seed()</a>.</p>

</div>
</div>
<a class="anchor" id="a5a44a44cb9212f0097f9beec79cc8d41"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define S2_MAX&#160;&#160;&#160;2147483422</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Definition at line <a class="el" href="rand-clcg4_8c_source.html#l00146">146</a> of file <a class="el" href="rand-clcg4_8c_source.html">rand-clcg4.c</a>.</p>

<p>Referenced by <a class="el" href="rand-clcg4_8c_source.html#l00153">clamp_seed()</a>.</p>

</div>
</div>
<a class="anchor" id="ac708ebfb62ad4528bedaeffbe28a3e06"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define S3_MAX&#160;&#160;&#160;2147483322</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Definition at line <a class="el" href="rand-clcg4_8c_source.html#l00147">147</a> of file <a class="el" href="rand-clcg4_8c_source.html">rand-clcg4.c</a>.</p>

<p>Referenced by <a class="el" href="rand-clcg4_8c_source.html#l00153">clamp_seed()</a>.</p>

</div>
</div>
<h2 class="groupheader">Function Documentation</h2>
<a class="anchor" id="af6fe13cfedc4e727feee7b28869e036e"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void clamp_seed </td>
          <td>(</td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>s</em>[4]</td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">
<p>These seeds MUST adhere to these requirements. This is explicitly stated in L'Ecuyer and Andres (1997) </p>

<p>Definition at line <a class="el" href="rand-clcg4_8c_source.html#l00153">153</a> of file <a class="el" href="rand-clcg4_8c_source.html">rand-clcg4.c</a>.</p>

<p>References <a class="el" href="rand-clcg4_8c_source.html#l00144">S0_MAX</a>, <a class="el" href="rand-clcg4_8c_source.html#l00145">S1_MAX</a>, <a class="el" href="rand-clcg4_8c_source.html#l00146">S2_MAX</a>, and <a class="el" href="rand-clcg4_8c_source.html#l00147">S3_MAX</a>.</p>

<p>Referenced by <a class="el" href="rand-clcg4_8c_source.html#l00338">rng_init()</a>, and <a class="el" href="rand-clcg4_8c_source.html#l00181">rng_set_seed()</a>.</p>

<p><div class="dynheader">
Here is the caller graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="rand-clcg4_8c_af6fe13cfedc4e727feee7b28869e036e_icgraph.png" border="0" usemap="#rand-clcg4_8c_af6fe13cfedc4e727feee7b28869e036e_icgraph" alt=""/></div>
<map name="rand-clcg4_8c_af6fe13cfedc4e727feee7b28869e036e_icgraph" id="rand-clcg4_8c_af6fe13cfedc4e727feee7b28869e036e_icgraph">
<area shape="rect" id="node2" href="rand-clcg4_8h.html#a3c5ea1f9125b9534b62a80dbfa20dafb" title="rng_init" alt="" coords="165,5,229,32"/><area shape="rect" id="node8" href="rand-clcg4_8c.html#a9c251d8e1876abc122b55fe4156ce14c" title="rng_set_seed" alt="" coords="147,56,247,83"/><area shape="rect" id="node3" href="ross-random_8h.html#a5600e4cb011d29cc24a2408220d58909" title="tw_rand_init" alt="" coords="297,5,389,32"/><area shape="rect" id="node4" href="tw-pe_8c.html#a2a0e6607074d85f80badcf5f5da3547e" title="tw_pe_init" alt="" coords="438,5,519,32"/><area shape="rect" id="node5" href="network-mpi_8h.html#a625a50a6a03701b067693d7dc5ed483b" title="Starts the network library after option parsing. " alt="" coords="569,5,663,32"/><area shape="rect" id="node6" href="tw-setup_8c.html#a7d395f5590701f5526a161fcb1261b03" title="tw_init" alt="" coords="713,5,773,32"/><area shape="rect" id="node7" href="phold_8c.html#a3c04138a5bfe5d72780bb7e82a18e627" title="main" alt="" coords="821,5,872,32"/></map>
</div>
</p>

</div>
</div>
<a class="anchor" id="ac243c54261ecf17a1b848e9b9a2025a9"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">long long FindB </td>
          <td>(</td>
          <td class="paramtype">long long&#160;</td>
          <td class="paramname"><em>a</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">long long&#160;</td>
          <td class="paramname"><em>k</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">long long&#160;</td>
          <td class="paramname"><em>m</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<p>FindB B is <img class="formulaInl" alt="$ a_[i]^{m_[i] - 2} \mathrm{mod m_[i]} $" src="form_0.png"/> which is used in running the CLCG4 backwards Added by Chris Carothers, 5/15/98 </p>

<p>Definition at line <a class="el" href="rand-clcg4_8c_source.html#l00037">37</a> of file <a class="el" href="rand-clcg4_8c_source.html">rand-clcg4.c</a>.</p>

<p>Referenced by <a class="el" href="rand-clcg4_8c_source.html#l00338">rng_init()</a>.</p>

<p><div class="dynheader">
Here is the caller graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="rand-clcg4_8c_ac243c54261ecf17a1b848e9b9a2025a9_icgraph.png" border="0" usemap="#rand-clcg4_8c_ac243c54261ecf17a1b848e9b9a2025a9_icgraph" alt=""/></div>
<map name="rand-clcg4_8c_ac243c54261ecf17a1b848e9b9a2025a9_icgraph" id="rand-clcg4_8c_ac243c54261ecf17a1b848e9b9a2025a9_icgraph">
<area shape="rect" id="node2" href="rand-clcg4_8h.html#a3c5ea1f9125b9534b62a80dbfa20dafb" title="rng_init" alt="" coords="109,5,173,32"/><area shape="rect" id="node3" href="ross-random_8h.html#a5600e4cb011d29cc24a2408220d58909" title="tw_rand_init" alt="" coords="222,5,314,32"/><area shape="rect" id="node4" href="tw-pe_8c.html#a2a0e6607074d85f80badcf5f5da3547e" title="tw_pe_init" alt="" coords="363,5,445,32"/><area shape="rect" id="node5" href="network-mpi_8h.html#a625a50a6a03701b067693d7dc5ed483b" title="Starts the network library after option parsing. " alt="" coords="494,5,589,32"/><area shape="rect" id="node6" href="tw-setup_8c.html#a7d395f5590701f5526a161fcb1261b03" title="tw_init" alt="" coords="638,5,698,32"/><area shape="rect" id="node7" href="phold_8c.html#a3c04138a5bfe5d72780bb7e82a18e627" title="main" alt="" coords="747,5,797,32"/></map>
</div>
</p>

</div>
</div>
<a class="anchor" id="ab89ab01c93d79746cff9a7ed763b24d3"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int32_t MultModM </td>
          <td>(</td>
          <td class="paramtype">int32_t&#160;</td>
          <td class="paramname"><em>s</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int32_t&#160;</td>
          <td class="paramname"><em>t</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int32_t&#160;</td>
          <td class="paramname"><em>M</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">
<p>MultiModM See L'Ecuyer and Cote(1991).</p>
<p>Returns(s*t) MOD M. Assumes that -M &lt; s &lt; M and -M &lt; t &lt; M. </p>

<p>Definition at line <a class="el" href="rand-clcg4_8c_source.html#l00077">77</a> of file <a class="el" href="rand-clcg4_8c_source.html">rand-clcg4.c</a>.</p>

<p>References <a class="el" href="rand-clcg4_8c_source.html#l00020">H</a>.</p>

<p>Referenced by <a class="el" href="rand-clcg4_8c_source.html#l00338">rng_init()</a>, <a class="el" href="rand-clcg4_8c_source.html#l00239">rng_init_generator()</a>, and <a class="el" href="rand-clcg4_8c_source.html#l00265">tw_rand_initial_seed()</a>.</p>

<p><div class="dynheader">
Here is the caller graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="rand-clcg4_8c_ab89ab01c93d79746cff9a7ed763b24d3_icgraph.png" border="0" usemap="#rand-clcg4_8c_ab89ab01c93d79746cff9a7ed763b24d3_icgraph" alt=""/></div>
<map name="rand-clcg4_8c_ab89ab01c93d79746cff9a7ed763b24d3_icgraph" id="rand-clcg4_8c_ab89ab01c93d79746cff9a7ed763b24d3_icgraph">
<area shape="rect" id="node2" href="rand-clcg4_8h.html#a3c5ea1f9125b9534b62a80dbfa20dafb" title="rng_init" alt="" coords="167,5,231,32"/><area shape="rect" id="node8" href="rand-clcg4_8h.html#a29a7a9b6a079ced3ba8339a66856fa82" title="rng_init_generator" alt="" coords="136,56,261,83"/><area shape="rect" id="node10" href="ross-random_8h.html#a9179f0148c620729309111ad61a3fa5b" title="tw_rand_initial_seed" alt="" coords="310,107,450,133"/><area shape="rect" id="node3" href="ross-random_8h.html#a5600e4cb011d29cc24a2408220d58909" title="tw_rand_init" alt="" coords="334,5,426,32"/><area shape="rect" id="node4" href="tw-pe_8c.html#a2a0e6607074d85f80badcf5f5da3547e" title="tw_pe_init" alt="" coords="531,9,613,36"/><area shape="rect" id="node5" href="network-mpi_8h.html#a625a50a6a03701b067693d7dc5ed483b" title="Starts the network library after option parsing. " alt="" coords="698,21,793,48"/><area shape="rect" id="node6" href="tw-setup_8c.html#a7d395f5590701f5526a161fcb1261b03" title="tw_init" alt="" coords="846,24,906,51"/><area shape="rect" id="node7" href="phold_8c.html#a3c04138a5bfe5d72780bb7e82a18e627" title="main" alt="" coords="955,51,1005,77"/><area shape="rect" id="node9" href="rand-clcg4_8c.html#a9c251d8e1876abc122b55fe4156ce14c" title="rng_set_seed" alt="" coords="330,56,430,83"/><area shape="rect" id="node11" href="ross-extern_8h.html#a96c2fb54945c414a31ce0512c39622b0" title="tw_rand_init_streams" alt="" coords="499,81,645,108"/><area shape="rect" id="node12" href="tw-setup_8c.html#ae29dd6eba29314361ef334f6bf028210" title="tw_define_lps" alt="" coords="694,79,797,105"/></map>
</div>
</p>

</div>
</div>
<a class="anchor" id="aa596cdb21f9c04984cc4806d7357d542"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">double rng_gen_reverse_val </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structtw__rng__stream.html">tw_rng_stream</a> *&#160;</td>
          <td class="paramname"><em>g</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Definition at line <a class="el" href="rand-clcg4_8c_source.html#l00451">451</a> of file <a class="el" href="rand-clcg4_8c_source.html">rand-clcg4.c</a>.</p>

<p>References <a class="el" href="rand-clcg4_8h_source.html#l00011">tw_rng::b</a>, <a class="el" href="rand-clcg4_8h_source.html#l00037">tw_rng_stream::Cg</a>, <a class="el" href="rand-clcg4_8h_source.html#l00034">tw_rng_stream::count</a>, <a class="el" href="rand-clcg4_8h_source.html#l00016">tw_rng::m</a>, <a class="el" href="tw-util_8c_source.html#l00074">tw_error()</a>, and <a class="el" href="ross-extern_8h_source.html#l00164">TW_LOC</a>.</p>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="rand-clcg4_8c_aa596cdb21f9c04984cc4806d7357d542_cgraph.png" border="0" usemap="#rand-clcg4_8c_aa596cdb21f9c04984cc4806d7357d542_cgraph" alt=""/></div>
<map name="rand-clcg4_8c_aa596cdb21f9c04984cc4806d7357d542_cgraph" id="rand-clcg4_8c_aa596cdb21f9c04984cc4806d7357d542_cgraph">
<area shape="rect" id="node2" href="ross-extern_8h.html#a49ed2388aaae26e43280b7909c834aaa" title="tw_error" alt="" coords="197,5,267,32"/><area shape="rect" id="node3" href="network-mpi_8c.html#a2e139e8547a091c4c4ea0b445fe8dd1c" title="tw_net_abort" alt="" coords="315,5,413,32"/></map>
</div>
</p>

</div>
</div>
<a class="anchor" id="adc7b882f7220d319c89b7500c5d2395f"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">double rng_gen_val </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structtw__rng__stream.html">tw_rng_stream</a> *&#160;</td>
          <td class="paramname"><em>g</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Definition at line <a class="el" href="rand-clcg4_8c_source.html#l00392">392</a> of file <a class="el" href="rand-clcg4_8c_source.html">rand-clcg4.c</a>.</p>

<p>References <a class="el" href="rand-clcg4_8h_source.html#l00037">tw_rng_stream::Cg</a>, and <a class="el" href="rand-clcg4_8h_source.html#l00034">tw_rng_stream::count</a>.</p>

</div>
</div>
<a class="anchor" id="aaf057a5d3e55f2174f5100a2058f37c5"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void rng_get_state </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structtw__rng__stream.html">tw_rng_stream</a> *&#160;</td>
          <td class="paramname"><em>g</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>s</em>[4]&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Definition at line <a class="el" href="rand-clcg4_8c_source.html#l00212">212</a> of file <a class="el" href="rand-clcg4_8c_source.html">rand-clcg4.c</a>.</p>

<p>References <a class="el" href="rand-clcg4_8h_source.html#l00037">tw_rng_stream::Cg</a>.</p>

</div>
</div>
<a class="anchor" id="a3c5ea1f9125b9534b62a80dbfa20dafb"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="structtw__rng.html">tw_rng</a>* rng_init </td>
          <td>(</td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>v</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>w</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Definition at line <a class="el" href="rand-clcg4_8c_source.html#l00338">338</a> of file <a class="el" href="rand-clcg4_8c_source.html">rand-clcg4.c</a>.</p>

<p>References <a class="el" href="rand-clcg4_8h_source.html#l00017">tw_rng::a</a>, <a class="el" href="rand-clcg4_8h_source.html#l00019">tw_rng::avw</a>, <a class="el" href="rand-clcg4_8h_source.html#l00018">tw_rng::aw</a>, <a class="el" href="rand-clcg4_8h_source.html#l00011">tw_rng::b</a>, <a class="el" href="rand-clcg4_8c_source.html#l00153">clamp_seed()</a>, <a class="el" href="rand-clcg4_8c_source.html#l00037">FindB()</a>, <a class="el" href="ross-global_8c_source.html#l00031">g_tw_rng_seed</a>, <a class="el" href="rand-clcg4_8h_source.html#l00016">tw_rng::m</a>, <a class="el" href="rand-clcg4_8c_source.html#l00077">MultModM()</a>, <a class="el" href="rand-clcg4_8c_source.html#l00023">rng</a>, <a class="el" href="rand-clcg4_8h_source.html#l00022">tw_rng::seed</a>, <a class="el" href="tw-util_8c_source.html#l00203">tw_calloc()</a>, and <a class="el" href="ross-extern_8h_source.html#l00164">TW_LOC</a>.</p>

<p>Referenced by <a class="el" href="ross-random_8c_source.html#l00007">tw_rand_init()</a>.</p>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="rand-clcg4_8c_a3c5ea1f9125b9534b62a80dbfa20dafb_cgraph.png" border="0" usemap="#rand-clcg4_8c_a3c5ea1f9125b9534b62a80dbfa20dafb_cgraph" alt=""/></div>
<map name="rand-clcg4_8c_a3c5ea1f9125b9534b62a80dbfa20dafb_cgraph" id="rand-clcg4_8c_a3c5ea1f9125b9534b62a80dbfa20dafb_cgraph">
<area shape="rect" id="node2" href="rand-clcg4_8c.html#af6fe13cfedc4e727feee7b28869e036e" title="clamp_seed" alt="" coords="118,5,210,32"/><area shape="rect" id="node3" href="rand-clcg4_8c.html#ac243c54261ecf17a1b848e9b9a2025a9" title="Find B to run CLCG4 backwards. " alt="" coords="136,56,192,83"/><area shape="rect" id="node4" href="rand-clcg4_8c.html#ab89ab01c93d79746cff9a7ed763b24d3" title="Returns(s*t) MOD M. " alt="" coords="123,107,205,133"/><area shape="rect" id="node5" href="ross-extern_8h.html#a445b1ed30cd2e8ef1f837e782a339a70" title="tw_calloc" alt="" coords="125,157,203,184"/><area shape="rect" id="node6" href="tw-util_8c.html#a57c62eebb6371a6d0d5ea5043f12f91b" title="pool_alloc" alt="" coords="259,132,339,159"/><area shape="rect" id="node8" href="tw-util_8c.html#a653cb2b88ee27b886ba5c854d5a0ba5c" title="tw_error" alt="" coords="264,183,333,209"/><area shape="rect" id="node7" href="tw-util_8c.html#a0611e23c33bb8c31272e79d876b8bcb0" title="my_malloc" alt="" coords="393,132,479,159"/><area shape="rect" id="node9" href="network-mpi_8c.html#a2e139e8547a091c4c4ea0b445fe8dd1c" title="tw_net_abort" alt="" coords="387,183,485,209"/></map>
</div>
</p>

<p><div class="dynheader">
Here is the caller graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="rand-clcg4_8c_a3c5ea1f9125b9534b62a80dbfa20dafb_icgraph.png" border="0" usemap="#rand-clcg4_8c_a3c5ea1f9125b9534b62a80dbfa20dafb_icgraph" alt=""/></div>
<map name="rand-clcg4_8c_a3c5ea1f9125b9534b62a80dbfa20dafb_icgraph" id="rand-clcg4_8c_a3c5ea1f9125b9534b62a80dbfa20dafb_icgraph">
<area shape="rect" id="node2" href="ross-random_8h.html#a5600e4cb011d29cc24a2408220d58909" title="tw_rand_init" alt="" coords="118,5,210,32"/><area shape="rect" id="node3" href="tw-pe_8c.html#a2a0e6607074d85f80badcf5f5da3547e" title="tw_pe_init" alt="" coords="259,5,341,32"/><area shape="rect" id="node4" href="network-mpi_8h.html#a625a50a6a03701b067693d7dc5ed483b" title="Starts the network library after option parsing. " alt="" coords="390,5,485,32"/><area shape="rect" id="node5" href="tw-setup_8c.html#a7d395f5590701f5526a161fcb1261b03" title="tw_init" alt="" coords="534,5,594,32"/><area shape="rect" id="node6" href="phold_8c.html#a3c04138a5bfe5d72780bb7e82a18e627" title="main" alt="" coords="643,5,693,32"/></map>
</div>
</p>

</div>
</div>
<a class="anchor" id="a29a7a9b6a079ced3ba8339a66856fa82"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void rng_init_generator </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structtw__rng__stream.html">tw_rng_stream</a> *&#160;</td>
          <td class="paramname"><em>g</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="rand-clcg4_8h.html#a3481da76773e3f2621af85e5865484a5">SeedType</a>&#160;</td>
          <td class="paramname"><em>Where</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Definition at line <a class="el" href="rand-clcg4_8c_source.html#l00239">239</a> of file <a class="el" href="rand-clcg4_8c_source.html">rand-clcg4.c</a>.</p>

<p>References <a class="el" href="rand-clcg4_8h_source.html#l00018">tw_rng::aw</a>, <a class="el" href="rand-clcg4_8h_source.html#l00037">tw_rng_stream::Cg</a>, <a class="el" href="rand-clcg4_8h_source.html#l00035">tw_rng_stream::Ig</a>, <a class="el" href="rand-clcg4_8h_source.html#l00027">InitialSeed</a>, <a class="el" href="rand-clcg4_8h_source.html#l00027">LastSeed</a>, <a class="el" href="rand-clcg4_8h_source.html#l00036">tw_rng_stream::Lg</a>, <a class="el" href="rand-clcg4_8h_source.html#l00016">tw_rng::m</a>, <a class="el" href="rand-clcg4_8c_source.html#l00077">MultModM()</a>, and <a class="el" href="rand-clcg4_8h_source.html#l00027">NewSeed</a>.</p>

<p>Referenced by <a class="el" href="rand-clcg4_8c_source.html#l00181">rng_set_seed()</a>.</p>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="rand-clcg4_8c_a29a7a9b6a079ced3ba8339a66856fa82_cgraph.png" border="0" usemap="#rand-clcg4_8c_a29a7a9b6a079ced3ba8339a66856fa82_cgraph" alt=""/></div>
<map name="rand-clcg4_8c_a29a7a9b6a079ced3ba8339a66856fa82_cgraph" id="rand-clcg4_8c_a29a7a9b6a079ced3ba8339a66856fa82_cgraph">
<area shape="rect" id="node2" href="rand-clcg4_8c.html#ab89ab01c93d79746cff9a7ed763b24d3" title="Returns(s*t) MOD M. " alt="" coords="179,5,261,32"/></map>
</div>
</p>

<p><div class="dynheader">
Here is the caller graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="rand-clcg4_8c_a29a7a9b6a079ced3ba8339a66856fa82_icgraph.png" border="0" usemap="#rand-clcg4_8c_a29a7a9b6a079ced3ba8339a66856fa82_icgraph" alt=""/></div>
<map name="rand-clcg4_8c_a29a7a9b6a079ced3ba8339a66856fa82_icgraph" id="rand-clcg4_8c_a29a7a9b6a079ced3ba8339a66856fa82_icgraph">
<area shape="rect" id="node2" href="rand-clcg4_8c.html#a9c251d8e1876abc122b55fe4156ce14c" title="rng_set_seed" alt="" coords="179,5,279,32"/></map>
</div>
</p>

</div>
</div>
<a class="anchor" id="aa97731a64b1cf687109f7a5f8f519c68"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void rng_put_state </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structtw__rng__stream.html">tw_rng_stream</a> *&#160;</td>
          <td class="paramname"><em>g</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>s</em>[4]&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Definition at line <a class="el" href="rand-clcg4_8c_source.html#l00226">226</a> of file <a class="el" href="rand-clcg4_8c_source.html">rand-clcg4.c</a>.</p>

<p>References <a class="el" href="rand-clcg4_8h_source.html#l00037">tw_rng_stream::Cg</a>.</p>

</div>
</div>
<a class="anchor" id="a9c251d8e1876abc122b55fe4156ce14c"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void rng_set_seed </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structtw__rng__stream.html">tw_rng_stream</a> *&#160;</td>
          <td class="paramname"><em>g</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>s</em>[4]&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Definition at line <a class="el" href="rand-clcg4_8c_source.html#l00181">181</a> of file <a class="el" href="rand-clcg4_8c_source.html">rand-clcg4.c</a>.</p>

<p>References <a class="el" href="rand-clcg4_8c_source.html#l00153">clamp_seed()</a>, <a class="el" href="rand-clcg4_8h_source.html#l00035">tw_rng_stream::Ig</a>, <a class="el" href="rand-clcg4_8h_source.html#l00027">InitialSeed</a>, and <a class="el" href="rand-clcg4_8c_source.html#l00239">rng_init_generator()</a>.</p>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="rand-clcg4_8c_a9c251d8e1876abc122b55fe4156ce14c_cgraph.png" border="0" usemap="#rand-clcg4_8c_a9c251d8e1876abc122b55fe4156ce14c_cgraph" alt=""/></div>
<map name="rand-clcg4_8c_a9c251d8e1876abc122b55fe4156ce14c_cgraph" id="rand-clcg4_8c_a9c251d8e1876abc122b55fe4156ce14c_cgraph">
<area shape="rect" id="node2" href="rand-clcg4_8c.html#af6fe13cfedc4e727feee7b28869e036e" title="clamp_seed" alt="" coords="171,5,263,32"/><area shape="rect" id="node3" href="rand-clcg4_8c.html#a29a7a9b6a079ced3ba8339a66856fa82" title="rng_init_generator" alt="" coords="155,56,280,83"/><area shape="rect" id="node4" href="rand-clcg4_8c.html#ab89ab01c93d79746cff9a7ed763b24d3" title="Returns(s*t) MOD M. " alt="" coords="328,56,411,83"/></map>
</div>
</p>

</div>
</div>
<a class="anchor" id="ad0fa533d1469c99034b45cd302a5134c"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void rng_write_state </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structtw__rng__stream.html">tw_rng_stream</a> *&#160;</td>
          <td class="paramname"><em>g</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">FILE *&#160;</td>
          <td class="paramname"><em>f</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Definition at line <a class="el" href="rand-clcg4_8c_source.html#l00198">198</a> of file <a class="el" href="rand-clcg4_8c_source.html">rand-clcg4.c</a>.</p>

<p>References <a class="el" href="rand-clcg4_8h_source.html#l00037">tw_rng_stream::Cg</a>.</p>

</div>
</div>
<a class="anchor" id="a96c2fb54945c414a31ce0512c39622b0"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void tw_rand_init_streams </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structtw__lp.html">tw_lp</a> *&#160;</td>
          <td class="paramname"><em>lp</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned int&#160;</td>
          <td class="paramname"><em>nstreams</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Definition at line <a class="el" href="rand-clcg4_8c_source.html#l00320">320</a> of file <a class="el" href="rand-clcg4_8c_source.html">rand-clcg4.c</a>.</p>

<p>References <a class="el" href="ross-global_8c_source.html#l00029">g_tw_nRNG_per_lp</a>, <a class="el" href="ross-types_8h_source.html#l00306">tw_lp::gid</a>, <a class="el" href="ross-types_8h_source.html#l00317">tw_lp::rng</a>, <a class="el" href="tw-util_8c_source.html#l00203">tw_calloc()</a>, <a class="el" href="tw-util_8c_source.html#l00074">tw_error()</a>, <a class="el" href="ross-extern_8h_source.html#l00164">TW_LOC</a>, and <a class="el" href="rand-clcg4_8c_source.html#l00265">tw_rand_initial_seed()</a>.</p>

<p>Referenced by <a class="el" href="tw-setup_8c_source.html#l00218">tw_define_lps()</a>.</p>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="rand-clcg4_8c_a96c2fb54945c414a31ce0512c39622b0_cgraph.png" border="0" usemap="#rand-clcg4_8c_a96c2fb54945c414a31ce0512c39622b0_cgraph" alt=""/></div>
<map name="rand-clcg4_8c_a96c2fb54945c414a31ce0512c39622b0_cgraph" id="rand-clcg4_8c_a96c2fb54945c414a31ce0512c39622b0_cgraph">
<area shape="rect" id="node2" href="ross-extern_8h.html#a445b1ed30cd2e8ef1f837e782a339a70" title="tw_calloc" alt="" coords="232,56,309,83"/><area shape="rect" id="node7" href="ross-extern_8h.html#a49ed2388aaae26e43280b7909c834aaa" title="tw_error" alt="" coords="236,107,305,133"/><area shape="rect" id="node8" href="rand-clcg4_8c.html#a9179f0148c620729309111ad61a3fa5b" title="tw_rand_initial_seed" alt="" coords="201,157,341,184"/><area shape="rect" id="node3" href="tw-util_8c.html#a57c62eebb6371a6d0d5ea5043f12f91b" title="pool_alloc" alt="" coords="391,5,471,32"/><area shape="rect" id="node5" href="tw-util_8c.html#a653cb2b88ee27b886ba5c854d5a0ba5c" title="tw_error" alt="" coords="396,56,465,83"/><area shape="rect" id="node4" href="tw-util_8c.html#a0611e23c33bb8c31272e79d876b8bcb0" title="my_malloc" alt="" coords="527,5,612,32"/><area shape="rect" id="node6" href="network-mpi_8c.html#a2e139e8547a091c4c4ea0b445fe8dd1c" title="tw_net_abort" alt="" coords="521,81,618,108"/><area shape="rect" id="node9" href="rand-clcg4_8c.html#ab89ab01c93d79746cff9a7ed763b24d3" title="Returns(s*t) MOD M. " alt="" coords="389,157,472,184"/></map>
</div>
</p>

<p><div class="dynheader">
Here is the caller graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="rand-clcg4_8c_a96c2fb54945c414a31ce0512c39622b0_icgraph.png" border="0" usemap="#rand-clcg4_8c_a96c2fb54945c414a31ce0512c39622b0_icgraph" alt=""/></div>
<map name="rand-clcg4_8c_a96c2fb54945c414a31ce0512c39622b0_icgraph" id="rand-clcg4_8c_a96c2fb54945c414a31ce0512c39622b0_icgraph">
<area shape="rect" id="node2" href="tw-setup_8c.html#ae29dd6eba29314361ef334f6bf028210" title="tw_define_lps" alt="" coords="201,5,303,32"/><area shape="rect" id="node3" href="phold_8c.html#a3c04138a5bfe5d72780bb7e82a18e627" title="main" alt="" coords="352,5,403,32"/></map>
</div>
</p>

</div>
</div>
<a class="anchor" id="a9179f0148c620729309111ad61a3fa5b"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void tw_rand_initial_seed </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structtw__rng__stream.html">tw_rng_stream</a> *&#160;</td>
          <td class="paramname"><em>g</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="ross_8h.html#a911515dff2fb79886a16ed44df5f9d20">tw_lpid</a>&#160;</td>
          <td class="paramname"><em>id</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Definition at line <a class="el" href="rand-clcg4_8c_source.html#l00265">265</a> of file <a class="el" href="rand-clcg4_8c_source.html">rand-clcg4.c</a>.</p>

<p>References <a class="el" href="rand-clcg4_8h_source.html#l00019">tw_rng::avw</a>, <a class="el" href="rand-clcg4_8h_source.html#l00034">tw_rng_stream::count</a>, <a class="el" href="rand-clcg4_8h_source.html#l00016">tw_rng::m</a>, <a class="el" href="rand-clcg4_8c_source.html#l00077">MultModM()</a>, and <a class="el" href="rand-clcg4_8h_source.html#l00022">tw_rng::seed</a>.</p>

<p>Referenced by <a class="el" href="rand-clcg4_8c_source.html#l00320">tw_rand_init_streams()</a>.</p>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="rand-clcg4_8c_a9179f0148c620729309111ad61a3fa5b_cgraph.png" border="0" usemap="#rand-clcg4_8c_a9179f0148c620729309111ad61a3fa5b_cgraph" alt=""/></div>
<map name="rand-clcg4_8c_a9179f0148c620729309111ad61a3fa5b_cgraph" id="rand-clcg4_8c_a9179f0148c620729309111ad61a3fa5b_cgraph">
<area shape="rect" id="node2" href="rand-clcg4_8c.html#ab89ab01c93d79746cff9a7ed763b24d3" title="Returns(s*t) MOD M. " alt="" coords="195,5,277,32"/></map>
</div>
</p>

<p><div class="dynheader">
Here is the caller graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="rand-clcg4_8c_a9179f0148c620729309111ad61a3fa5b_icgraph.png" border="0" usemap="#rand-clcg4_8c_a9179f0148c620729309111ad61a3fa5b_icgraph" alt=""/></div>
<map name="rand-clcg4_8c_a9179f0148c620729309111ad61a3fa5b_icgraph" id="rand-clcg4_8c_a9179f0148c620729309111ad61a3fa5b_icgraph">
<area shape="rect" id="node2" href="ross-extern_8h.html#a96c2fb54945c414a31ce0512c39622b0" title="tw_rand_init_streams" alt="" coords="195,5,341,32"/><area shape="rect" id="node3" href="tw-setup_8c.html#ae29dd6eba29314361ef334f6bf028210" title="tw_define_lps" alt="" coords="390,5,493,32"/><area shape="rect" id="node4" href="phold_8c.html#a3c04138a5bfe5d72780bb7e82a18e627" title="main" alt="" coords="541,5,592,32"/></map>
</div>
</p>

</div>
</div>
<h2 class="groupheader">Variable Documentation</h2>
<a class="anchor" id="a5bb18b1128fadea0f468ea648f656ce1"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="structtw__rng.html">tw_rng</a>* rng = NULL</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Definition at line <a class="el" href="rand-clcg4_8c_source.html#l00023">23</a> of file <a class="el" href="rand-clcg4_8c_source.html">rand-clcg4.c</a>.</p>

<p>Referenced by <a class="el" href="rand-clcg4_8c_source.html#l00338">rng_init()</a>.</p>

</div>
</div>
<a class="anchor" id="ac6110bfd61d392bab210049c5f6f8fa3"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int32_t seed[4] = { 11111111, 22222222, 33333333, 44444444 }</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Definition at line <a class="el" href="rand-clcg4_8c_source.html#l00026">26</a> of file <a class="el" href="rand-clcg4_8c_source.html">rand-clcg4.c</a>.</p>

</div>
</div>
</div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.6
</small></address>
</body>
</html>
